package com.version1_1.model;

import com.util.property.Properties;

import java.io.Serializable;

public class User implements Serializable {

    private static final long serialVersionUID = 1L;

    private long userId;
    private String userName;
    private String userPasswd;
    private String tokenRY;
    int userCoin;
    String userPhoto;
    String userSex;
    String userMail;
    String userTel;
    int userReadedNum;
    String userFocusId;
    String inviteCode;
    String inputInviteCode;

    public String getInviteCode() {
        return inviteCode;
    }

    public void setInviteCode(String inviteCode) {
        this.inviteCode = inviteCode;
    }

    public String getInputInviteCode() {
        return inputInviteCode;
    }

    public void setInputInviteCode(String inputInviteCode) {
        this.inputInviteCode = inputInviteCode;
    }

    public String getTokenRY() {
        return tokenRY;
    }

    public void setTokenRY(String tokenRY) {
        this.tokenRY = tokenRY;
    }

    public long getUserId() {
        return userId;
    }

    public void setUserId(long userId) {
        this.userId = userId;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getUserPasswd() {
        return userPasswd;
    }

    public void setUserPasswd(String userPasswd) {
        this.userPasswd = userPasswd;
    }

    public int getUserCoin() {
        return userCoin;
    }

    public void setUserCoin(int userCoin) {
        this.userCoin = userCoin;
    }

    public String getUserSex() {
        return userSex;
    }

    public void setUserSex(String userSex) {
        this.userSex = userSex;
    }

    public String getUserMail() {
        return userMail;
    }

    public void setUserMail(String userMail) {
        this.userMail = userMail;
    }

    public String getUserTel() {
        return userTel;
    }

    public void setUserTel(String userTel) {
        this.userTel = userTel;
    }

    public int getUserReadedNum() {
        return userReadedNum;
    }

    public void setUserReadedNum(int userReadedNum) {
        this.userReadedNum = userReadedNum;
    }

    public String getUserFocusId() {
        return userFocusId;
    }

    public void setUserFocusId(String userFocusId) {
        this.userFocusId = userFocusId;
    }

    public static long getSerialversionuid() {
        return serialVersionUID;
    }

    public String getUserPhoto() {
        return userPhoto;
    }

    public void setUserPhoto(String userPhoto) {
        this.userPhoto = userPhoto;
    }

    /**
     * 类User toString方法
     */
    public String toString() {

        String photoString = "";
        if (getUserPhoto() != null) {
            photoString = getUserPhoto() + Properties.ImageQuality;
        }

        return "\"userId\":" + getUserId() + ","
                + "\"userName\":\"" + getUserName() + "\","
                + "\"userPhoto\":\"" + photoString + "\","
                + "\"userSex\":\"" + getUserSex() + "\"";
    }
}
